project(chelper)

# set a alias name
set(SRC_ROOT "${CMAKE_CURRENT_SOURCE_DIR}")

# set configure file to pass ther version number to the source code
configure_file(${PROJECT_SOURCE_DIR}/utils/CHelperConfigure.h.in ${PROJECT_BINARY_DIR}/utils/CHelperConfigure.h) 

# generate executable file
add_executable(${PROJECT_NAME} ${SRC_ROOT}/helper.cpp)

# include utils directory
add_subdirectory(utils)
add_subdirectory(memory)

# add directory to the list of paths to search for include files
target_include_directories(${PROJECT_NAME} PRIVATE
                            ${PROJECT_BINARY_DIR}
                            ${SRC_ROOT})

# link libraries
target_link_libraries(${PROJECT_NAME} PRIVATE
                        chelper::_utils
                        chelper::_memory
                        glog::glog)